package com.wad.common;

import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.AllArgsConstructor;
import lombok.Data;

/**
 * @author wad
 * @date 2022/11/11 15:56
 * @project JWT_DEMO2
 **/

@Data
@AllArgsConstructor
@JsonInclude(JsonInclude.Include.NON_NULL)
public class ResponseResult<T> {


    /**
     * 状态码
     */
    private Integer code;

    /**
     * 响应消息
     */
    private String msg;

    /**
     * 响应数据
     */
    private T data;

    public ResponseResult(Integer code,String msg)
    {
        this.code=code;
        this.msg=msg;
    }

    public ResponseResult(Integer code,T data){
        this.code=code;
        this.data=data;
    }
}
